home *** CD-ROM | disk | FTP | other *** search
/ Maximum CD 2009 January / maximum-cd-2009-01.iso / DiscContents / Utilities.erase.exe / {app} / HTML / Common / norightclick.js < prev    next >
Encoding:
JavaScript  |  2007-03-30  |  399 b   |  19 lines

  1. // Disable right click
  2. function click(e) {
  3. if (document.all) {
  4. if (event.button==2||event.button==3) {
  5. oncontextmenu='return false';
  6. setInterval("window.status=''",10);
  7. }
  8. }
  9. if (document.layers) {
  10. if (e.which == 3) {
  11. oncontextmenu='return false';
  12. setInterval("window.status=''",10);
  13. }
  14. }
  15. }
  16. if (document.layers) {
  17. document.captureEvents(Event.MOUSEDOWN);
  18. }
  19. document.onmousedown=click;